
<%@ page import="click.Machine" %>
<html>
    <head>
        <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
        <meta name="layout" content="main" />
        <g:set var="entityName" value="${message(code: 'machine.label', default: 'Machine')}" />
        <title><g:message code="default.list.label" args="[entityName]" /></title>
        <g:javascript library="jquery"/>
        <script language="JavaScript">
        <!--
            $(function(){
            
            $(".link").mouseover(function(){
                log("over = "  + event.clientX +"|"+ event.clientY + $(this).attr("href"));
            });
            $(".link").mouseout(function(){
                log("out = " +$(this).attr("href"));
            });
            $(".link").click(function(){
                log("click = "  +$(this).attr("href"));
                println(event.clientX , event.clientY , "#00F");
                return false;
            });
            $("body").mousemove(function(){
             
                println(event.clientX , event.clientY , "red");
            });

            function log(c){
                $(".log").val($(".log").val() +"\n"+ c  + "    " + new Date().getTime());
            }

            function println(x , y , color){
                //body.insertAdjacentHTML("AfterBegin",str)
                $("body").append('<span style="position:absolute;left:'+parseInt(x)+';top:' + parseInt(y) + ';height:3;width:3;font-size:1px;background-color:'+color+';filter:alpha(opacity=50);"></span>')
            }
            });
        //-->
        </script>
    </head>
    <body>
       <div class="body">
            
            <div class="list">
                <table>
                    <thead>
                        <tr>
                        
                            <g:sortableColumn property="id" title="${message(code: 'machine.id.label', default: 'Id')}" />
                         
                        </tr>
                    </thead>
                    <tbody>
                    <g:each in="${machineInstanceList}" status="i" var="machineInstance">
                        <tr class="${(i % 2) == 0 ? 'odd' : 'even'}">
                        
                            <td><a href="http://www.baidu.com" class="link">${machineInstance}中中国人民共和国</a></td>
                     
                        </tr>
                    </g:each>
                    </tbody>
                </table>
            </div>
            
        </div>
        <textarea class="log" rows="10" cols="100" style="width: 600px; height:200px;"></textarea>
    </body>
</html>
